﻿using System;
using System.Web.Mvc;

namespace Facebook.Web.Mvc
{
    public class FacebookViewUserControl : ViewUserControl
    {
        public FacebookViewUserControl()
        {
            this.Fbml = new FbmlHelper(this.ViewContext);
        }

        public FbmlHelper Fbml { get; set; }
        public FacebookWebContext FbContext { get { return FacebookWebContext.Current; } }
        public FacebookWebRequest FbRequest { get { return FacebookWebRequest.Current; } }
        public FacebookWebSession FbSession { get { return FacebookWebSession.Current; } }
    }

    public class FacebookViewUserControl<TModel> : ViewUserControl<TModel>
        where TModel : class
    {
        public FacebookViewUserControl()
        {
            this.Fbml = new FbmlHelper(this.ViewContext);
        }

        public FbmlHelper Fbml { get; set; }
        public FacebookWebContext FbContext { get { return FacebookWebContext.Current; } }
        public FacebookWebRequest FbRequest { get { return FacebookWebRequest.Current; } }
        public FacebookWebSession FbSession { get { return FacebookWebSession.Current; } }
    }
}